<!DOCTYPE html>
<!-- saved from url=(0040)https://qtools.cloud/query_personno.html -->
<html lang="zh"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>
        身份证号校验与信息查询，超全工具，在线工具集合
    </title>
    <meta name="description" content="身份证号校验工具，检查身份证号是否正确，解析身份证号出生地、生日、性别等信息">
    <meta http-equiv="X-UA-Compatible" content="IE=Edge">
    
    <meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="baidu-site-verification" content="code-QgIxLd8nDU">
    <meta name="msvalidate.01" content="147CD3A95A6BE138B6E280C62B275E74">
    <meta name="google-site-verification" content="f_tqkl8XWx7ZkeNAO5n6UPQu_NDXSv5W10AWwXN-u0M">
    <meta name="sogou_site_verification" content="f54b3slFWX">
    <meta name="360-site-verification" content="e9fdc2078aec0c99afa4b33b5ca986e3">
    <!--引入Bootstrap-->
    <link href="./身份证号校验与信息查询，超全工具，在线工具集合_files/bootstrap.min.css" rel="stylesheet" crossorigin="anonymous">
    <style type="text/css">
    .t-small-margin {
        margin-top: 10px;
    }

    .top1-link {
        margin-top: 10px;
        position:
            relative;
        height: 40px;
    }
    </style>
    <!--jQuery文件。务必在bootstrap.min.js之前引入-->
    <script src="./身份证号校验与信息查询，超全工具，在线工具集合_files/jquery.min.js.下载" crossorigin="anonymous">
    </script>
    <!--最新的Bootstrap核心JavaScript文件-->
    <script src="./身份证号校验与信息查询，超全工具，在线工具集合_files/bootstrap.min.js.下载" crossorigin="anonymous">
    </script>
    <!--HTML5 Shiv和Respond.js用于让IE8支持HTML5元素和媒体查询-->
    <!--注意：如果通过file:[if lt IE 9]>
      <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js">
      </script>
      <script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js">
      </script>
    <![endif]-->
    <link rel="stylesheet" href="./身份证号校验与信息查询，超全工具，在线工具集合_files/bootstrap-select.min.css">
    <script src="./身份证号校验与信息查询，超全工具，在线工具集合_files/bootstrap-select.min.js.下载"></script>
    <script language="JavaScript">
    function fresh() {
        if (location.href.indexOf("?reload=true") < 0 && location.href.indexOf("?reload=true") > 0) {
            location.href += "?reload=true";
        }
    }
    setTimeout("fresh()", 50)
    </script>
</head>

<body style="background:#f6f6f6;color: #333;">
    <h1 style="display: none;">身份证号校验工具，检查身份证号是否正确，解析身份证号出生地、生日、性别等信息</h1>
    <nav class="navbar navbar-inverse" role="navigation" style="border-radius: 0">
        <div class="container clear-both">
            <!--导航头部-->
            <div class="navbar-header float-left col-md-2 column" style="margin-right:-15px;margin-left:-15px">
                <!--品牌名称或logo-->
                <a class="navbar-brand" style="padding:0px 15px" href="https://qtools.cloud/query_personno.html#">
                    <img src="./身份证号校验与信息查询，超全工具，在线工具集合_files/logo.png" alt="超全工具-各种工具集合">
                </a>
            </div>
            <!--导航项目-->
            <div class="collapse navbar-collapse navbar-collapse-example float-left col-md-7 column">
                <!--一般导航项目-->
<ul class="nav navbar-nav"><li class="dropdown  active" id="dropdown0" data-target="#dropdown0"><a href="https://qtools.cloud/query_personno.html#" class="dropdown-toggle" data-toggle="dropdown">图片处理<b class="caret"></b></a><ul class="dropdown-menu" role="menu"><li class="grade-li grade-li-active"><a href="https://qtools.cloud/pic_compress" class="" target="_blank">图片在线压缩</a></li>
<li class="grade-li grade-li-active"><a href="https://qtools.cloud/pic_cut" class="" target="_blank">图片在线切割/九宫格</a></li>
</ul></li></ul><ul class="nav navbar-nav"><li class="dropdown  active" id="dropdown0" data-target="#dropdown0"><a href="https://qtools.cloud/query_personno.html#" class="dropdown-toggle" data-toggle="dropdown">查询<b class="caret"></b></a><ul class="dropdown-menu" role="menu"><li class="grade-li grade-li-active"><a href="https://qtools.cloud/query_areacode" class="" target="_blank">行政区划代码</a></li>
<li class="grade-li grade-li-active"><a href="https://qtools.cloud/query_personno" class="" target="_blank">身份证号校验与信息查询</a></li>
<li class="grade-li grade-li-active"><a href="https://qtools.cloud/personno_rand_gen" class="" target="_blank">随机身份证号生成器</a></li>
</ul></li></ul><ul class="nav navbar-nav"><li class="dropdown  active" id="dropdown0" data-target="#dropdown0"><a href="https://qtools.cloud/query_personno.html#" class="dropdown-toggle" data-toggle="dropdown">JSON工具<b class="caret"></b></a><ul class="dropdown-menu" role="menu"><li class="grade-li grade-li-active"><a href="https://qtools.cloud/json_format" class="" target="_blank">JSON格式化</a></li>
<li class="grade-li grade-li-active"><a href="https://qtools.cloud/json_compress" class="" target="_blank">JSON压缩</a></li>
<li class="grade-li grade-li-active"><a href="https://qtools.cloud/json2xml" class="" target="_blank">JSON与XML互转</a></li>
</ul></li></ul><ul class="nav navbar-nav"><li class="dropdown  active" id="dropdown0" data-target="#dropdown0"><a href="https://qtools.cloud/query_personno.html#" class="dropdown-toggle" data-toggle="dropdown">时间/日期<b class="caret"></b></a><ul class="dropdown-menu" role="menu"><li class="grade-li grade-li-active"><a href="https://qtools.cloud/unix_timestamp" class="" target="_blank">时间戳与时间转换</a></li>
<li class="grade-li grade-li-active"><a href="https://qtools.cloud/vacation" class="" target="_blank">放假安排与放假倒计时</a></li>
</ul></li></ul><ul class="nav navbar-nav"><li class="dropdown  active" id="dropdown0" data-target="#dropdown0"><a href="https://qtools.cloud/query_personno.html#" class="dropdown-toggle" data-toggle="dropdown">编码/加解密<b class="caret"></b></a><ul class="dropdown-menu" role="menu"><li class="grade-li grade-li-active"><a href="https://qtools.cloud/encode_md5" class="" target="_blank">MD5加密</a></li>
<li class="grade-li grade-li-active"><a href="https://qtools.cloud/encode_base64" class="" target="_blank">BASE64编解码</a></li>
<li class="grade-li grade-li-active"><a href="https://qtools.cloud/encode_urlcode" class="" target="_blank">URL编解码</a></li>
</ul></li></ul><ul class="nav navbar-nav"><li class="dropdown  active" id="dropdown0" data-target="#dropdown0"><a href="https://qtools.cloud/query_personno.html#" class="dropdown-toggle" data-toggle="dropdown">其他<b class="caret"></b></a><ul class="dropdown-menu" role="menu"><li class="grade-li grade-li-active"><a href="https://qtools.cloud/txt_compare" class="" target="_blank">文本对比/代码合并</a></li>
<li class="grade-li grade-li-active"><a href="https://qtools.cloud/cron_gen" class="" target="_blank">cron在线生成器</a></li>
</ul></li></ul>            </div>
            <div class="col-md-3 column" style="display:inline-block;float:right;margin-top: 7px;">
                <div class="btn-group bootstrap-select show-tick form-control"><button type="button" class="btn dropdown-toggle btn-default" data-toggle="dropdown" role="button" title="输入关键字搜索功能"><span class="filter-option pull-left">输入关键字搜索功能</span>&nbsp;<span class="bs-caret"><span class="caret"></span></span></button><div class="dropdown-menu open" role="combobox"><div class="bs-searchbox"><input type="text" class="form-control" autocomplete="off" role="textbox" aria-label="Search"></div><ul class="dropdown-menu inner" role="listbox" aria-expanded="false"><li data-original-index="0" class="selected"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="true"><span class="text">输入关键字搜索功能</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="1"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">图片在线压缩</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="2"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">图片在线切割/九宫格</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="3"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">行政区划代码</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="4"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">身份证号校验与信息查询</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="5"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">随机身份证号生成器</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="6"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">JSON格式化</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="7"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">JSON压缩</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="8"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">JSON与XML互转</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="9"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">时间戳与时间转换</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="10"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">放假安排与放假倒计时</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="11"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">MD5加密</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="12"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">BASE64编解码</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="13"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">URL编解码</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="14"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">文本对比/代码合并</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li><li data-original-index="15"><a tabindex="0" class="" data-tokens="null" role="option" aria-disabled="false" aria-selected="false"><span class="text">cron在线生成器</span><span class="glyphicon glyphicon-ok check-mark"></span></a></li></ul></div><select class="selectpicker show-tick form-control" data-live-search="true" onchange="window.location=this.value;" data-size="8" tabindex="-98">
                    <option>输入关键字搜索功能</option>
                    <option value="/pic_compress">图片在线压缩</option><option value="/pic_cut">图片在线切割/九宫格</option><option value="/query_areacode">行政区划代码</option><option value="/query_personno">身份证号校验与信息查询</option><option value="/personno_rand_gen">随机身份证号生成器</option><option value="/json_format">JSON格式化</option><option value="/json_compress">JSON压缩</option><option value="/json2xml">JSON与XML互转</option><option value="/unix_timestamp">时间戳与时间转换</option><option value="/vacation">放假安排与放假倒计时</option><option value="/encode_md5">MD5加密</option><option value="/encode_base64">BASE64编解码</option><option value="/encode_urlcode">URL编解码</option><option value="/txt_compare">文本对比/代码合并</option><option value="/cron_gen">cron在线生成器</option>
                </select></div>
            </div>
        </div>
    </nav>
<div class="container">
      <ul class="nav nav-tabs tab-after custom-tab" style="width: 100%;">
         <li class="" classid="4" nvid="Array"><a class="cursor-pointer" href="https://qtools.cloud/query_areacode" data-recent="yes" target="_blank">行政区划代码</a></li><li class="" classid="4" nvid="Array"><a class="cursor-pointer" href="https://qtools.cloud/query_personno" data-recent="yes" target="_blank">身份证号校验与信息查询</a></li><li class="" classid="4" nvid="Array"><a class="cursor-pointer" href="https://qtools.cloud/personno_rand_gen" data-recent="yes" target="_blank">随机身份证号生成器</a></li>
      </ul>
    </div><!--      <div class="container t-small-margin">
        <ul class="top1-link">
            <a href="https://cloud.tencent.com/act/double11?spread_hash_key=5d4a44f990321135a114996d86a4b0eb" target="_blank" style="font-size: 14px;color:red;">
                腾讯云双十一特惠
            </a>
            <a href="/knownjson/demo/" target="_blank" style="font-size: 12px;color:black;">JSON的用法</a>
    </ul>
    </div>  -->
<script src="./身份证号校验与信息查询，超全工具，在线工具集合_files/const_area.common.js.下载"></script>
<script type="text/javascript">
function parse() {
    var v = document.getElementById('p_id_no').value;
    if (v == '') {
        return;
    }

    document.getElementById('inf_valid').innerHTML = '--';
    document.getElementById('info_birth').innerHTML = '--';
    document.getElementById('info_sex').innerHTML = '--';
    document.getElementById('info-place').innerHTML = '--';
    document.getElementById('inf_valid').style = "";

    document.getElementById('inf_no').innerHTML = v;
    if (v.length != 18) {
        document.getElementById('inf_valid').style = "color:#e60000";
        document.getElementById('inf_valid').innerHTML = '身份证号位数需要是18位，所输入位数为:' + v.length;
        return;
    }

    var ap = v.substring(0, 6);
    var ap1 = v.substring(0, 2);

    var infoplace = '';
    if (undefined != latest_area_code[ap]) {
        infoplace = latest_area_code[ap];

        var fa1 = ap.substring(0, 4) + '00';
        if (fa1 != ap && undefined != latest_area_code[fa1]) {
            infoplace = latest_area_code[fa1] + infoplace;
        }

        var fa2 = ap.substring(0, 2) + '0000';
        if (fa2 != ap && undefined != latest_area_code[fa2]) {
            infoplace = latest_area_code[fa2] + infoplace;
        }
    } else if (undefined != provinces[ap1]) {
        infoplace = provinces[ap1];
    } else {
        document.getElementById('inf_valid').style = "color:#e60000";
        document.getElementById('inf_valid').innerHTML = '前6位非法，身份证号前6位表示地区';
        return;
    }

    var bir_y = v.substring(6, 10);
    var bir_m = v.substring(10, 12);
    var bir_d = v.substring(12, 14);

    var bir_dt = bir_y + '-' + bir_m + '-' + bir_d;
    if (!checkDate(bir_dt)) {
        document.getElementById('inf_valid').style = "color:#e60000";
        document.getElementById('inf_valid').innerHTML = '第8-14位出生日期非法';
        return;
    }

    var sum = 0;
    let coefficient = [7, 9, 10, 5, 8, 4, 2, 1, 6, 3, 7, 9, 10, 5, 8, 4, 2];
    let checkDigitMap = ['1', '0', 'X', '9', '8', '7', '6', '5', '4', '3', '2'];
    for (var i = 0; i < 17; i++) {
        sum += v[i] * coefficient[i];
    }

    if (v[17] != checkDigitMap[sum % 11]) {
        document.getElementById('inf_valid').style = "color:#e60000";
        document.getElementById('inf_valid').innerHTML = '最后一位校验位错误';
        return;
    }

    document.getElementById('inf_valid').innerHTML = '身份证号格式正确';
    document.getElementById('info_birth').innerHTML = bir_dt;
    document.getElementById('info_sex').innerHTML = ((0 + v[16]) % 2 == 0) ? '女' : '男';
    document.getElementById('info-place').innerHTML = infoplace;
    // document.getElementById('info_y').innerHTML = infoplace;


}

function checkDate(value) {

    return (new Date(value).getDate() == value.substring(value.length - 2));

}
</script>
<div class="container">
    <h3 class="font-15 v-big-margin no-padding-v">身份证号校验与信息查询</h3>
    <div class="container t-small-margin"></div>
    <div class="container t-small-margin"></div>
    <div class="row clearfix">
 
        <div class="col-md-6 column">
            <div class="panel panel-danger">
                <div class="panel-body" style="color:#e11c07">
                    身份证号解析工具，本工具不会保存输入的身份证号，可放心使用。
                </div>
            </div>
            <input type="text" class="form-control" id="p_id_no" placeholder="输入18位身份证号，点击按钮进行查询" onkeyup="this.value=this.value.replace(/[^\dX]/g,&#39;&#39;) " onafterpaste="this.value=this.value.replace(/[^\dX]/g,&#39;&#39;) ">
            <div class="container t-small-margin"></div>
            <button type="button" class="btn btn-success" onclick="parse()">点击此处查询</button>
            <div class="container t-small-margin"></div>
            <div class="container t-small-margin"></div>
            <table class="table table-striped">
                <caption>身份证基本信息</caption>
                <tbody>
                    <tr>
                        <td>身份证号</td>
                        <td id="inf_no">370115200011147252</td>
                    </tr>
                    <tr>
                        <td>身份证号是否合法</td>
                        <td id="inf_valid" style="">身份证号格式正确</td>
                    </tr>
                    <tr>
                        <td>出生日期</td>
                        <td id="info_birth">2000-11-14</td>
                    </tr>
                    <tr>
                        <td>性别</td>
                        <td id="info_sex">男</td>
                    </tr>
                    <tr>
                        <td>出生地</td>
                        <td id="info-place">山东省济南市济阳区</td>
                    </tr>
                    <!--                     <tr>
                        <td>年龄</td>
                        <td id="info_y">--</td>
                    </tr> -->
                </tbody>
            </table>
        </div>
        <div class="col-md-6 column">
        </div>
    </div>
</div>

</body><div id="edge-translate-notifier-container" class="edge-translate-notifier-center"></div></html>